package itheima.ZuoYe03;

import java.util.ArrayList;
import java.util.List;
import java.util.stream.Stream;

public class Demo02 {
    public static void main(String[] args) {
        List<String> list = new ArrayList<>();
        list.add("张三丰");
        list.add("王思聪");
        list.add("张飞");
        list.add("刘晓敏");
        list.add("张靓颖");
        list.stream().filter(s -> s.startsWith("张")).forEach(s -> System.out.println(s));

    }
}
